package uutalk.netcloud.talk.app.di;

import android.app.Application;

import com.baidu.mapapi.SDKInitializer;
import com.uuzuche.lib_zxing.activity.ZXingLibrary;

import javax.inject.Inject;

import uutalk.netcloud.talk.BuildConfig;
import uutalk.netcloud.talk.base.util.thirdpart.BugtagsManager;
import uutalk.netcloud.talk.base.util.thirdpart.SpeechSynManager;

/**
 * Created by hujie on 16/6/22.
 *
 * 第三个初始化管理
 */
public class ThirdPartyManaer {

    @Inject
    public Application application;
  //  public RefWatcher refWatcher;



    private static ThirdPartyManaer thirdPartyManaer;


    public static ThirdPartyManaer getInstance() {
        if (thirdPartyManaer == null) {
            thirdPartyManaer = new ThirdPartyManaer();
        }
        return thirdPartyManaer;
    }

    private ThirdPartyManaer() {

    }

    public void initThirdParty() {
        initWatcher();
        initBugTags();
        initFIR();
        initZXING();
        initBaiduMap();
        initSpeech();

    }


    private void initBaiduMap() {
        SDKInitializer.initialize(application);
    }

    private void initZXING(){
        ZXingLibrary.initDisplayOpinion(application);
    }

    private void initFIR() {
     //   FIR.init(application);
    }

    private void initSpeech(){
        SpeechSynManager.getInstance().initSpeech(application);
    };
    private void initBugTags() {
        BugtagsManager.start(application);
    }


    public void watcher(Object o) {

    }

    private void initWatcher() {
        if (BuildConfig.DEBUG) {

        }
    }
}
